package com.itjob.scott.lesson03.action;

import com.itjob.scott.lesson03.dao.AnimalDao;

/**
 * 测试 HelloAction 就固定了
 * @author Administrator
 *
 */
public class HelloAction {
	
	private AnimalDao animalDao = null;
	
	
	public void sayHello(){
		//谁在叫  根本不知道  由下层决定
		System.out.println("say:" +animalDao.call());
	}


	public AnimalDao getAnimalDao() {
		return animalDao;
	}


	/**
	 * 谁要使用 HelloAction  就在使用前先设置好 setAnimalDao
	 * @param animalDao  setAnimalDao
	 */
	public void setAnimalDao(AnimalDao animalDao) {
		this.animalDao = animalDao;
	}
	
	
	
	

}
